package com.sisqorap.wakeuplight;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

public class ShowNotification extends BroadcastReceiver{
	@Override 
    public void onReceive(Context context, Intent intent){
        // Send a text notification to the screen.
        /*NotificationManager nm = (NotificationManager)context.getSystemService(Context.NOTIFICATION_SERVICE);
        String tickerText = context.getString(R.string.set_alarm);
        Notification notif = new Notification(R.drawable.time, tickerText, System.currentTimeMillis());
        PendingIntent contentIntent = PendingIntent.getActivity(context, 0, intent, 0);
        notif.setLatestEventInfo(context, context.getString(R.string.app_name), context.getString(R.string.repeating_received), contentIntent);
        
        notif.ledARGB = 0xFFff0000;
        notif.flags = Notification.FLAG_ONLY_ALERT_ONCE;
        notif.ledOnMS = 100;
        notif.ledOffMS = 100;*/
        Intent i = new Intent(context,SnoozeAlarm.class);
        //PendingIntent pendIntent = PendingIntent.getActivity(context, 0, i, 0);
        //notif.setLatestEventInfo(context, "Puzzel Alarm", "Snooze Alarm", pendIntent);
        
        // after a 100ms delay, vibrate for 250ms, pause for 100 ms and
        // then vibrate for 500ms.
        //notif.vibrate = new long[] { 100, 250, 100, 500};
        //notif.defaults |= Notification.DEFAULT_SOUND;        
        //nm.notify(0, notif);
        i.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
        //i.addFlags(Intent.FLAG_ACTIVITY_PREVIOUS_IS_TOP);
        context.startActivity(i); 
   }
}